/*
 * @Author: songtao
 * @Date: 2021-11-22 15:40:05
 * @LastEditTime: 2021-11-22 18:43:17
 * @FilePath: \vue-cars\vue-admin\src\utils\app.js
 */

import cookie from "cookie_js"

const adminToken = "admin_tokem"
const usernameKey = "username"

export function getToken(){
    return cookie.get(adminToken)
}

export function setToken(token){
    cookie.set(adminToken, token)
}

export function removeToken(){
    cookie.remove(adminToken)
}

export function setUserName(username){
    cookie.set(usernameKey, username)
}

export function getUserName(){
    return cookie.get(usernameKey)
}

export function removeUserName(){
    cookie.remove(usernameKey)
}